package com.nft.infrastructure.fisco.raw;

import org.fisco.bcos.sdk.abi.FunctionReturnDecoder;
import org.fisco.bcos.sdk.abi.TypeReference;
import org.fisco.bcos.sdk.abi.datatypes.*;
import org.fisco.bcos.sdk.abi.datatypes.generated.Int256;
import org.fisco.bcos.sdk.abi.datatypes.generated.tuples.generated.Tuple1;
import org.fisco.bcos.sdk.abi.datatypes.generated.tuples.generated.Tuple2;
import org.fisco.bcos.sdk.client.Client;
import org.fisco.bcos.sdk.contract.Contract;
import org.fisco.bcos.sdk.crypto.CryptoSuite;
import org.fisco.bcos.sdk.crypto.keypair.CryptoKeyPair;
import org.fisco.bcos.sdk.eventsub.EventCallback;
import org.fisco.bcos.sdk.model.CryptoType;
import org.fisco.bcos.sdk.model.TransactionReceipt;
import org.fisco.bcos.sdk.model.callback.TransactionCallback;
import org.fisco.bcos.sdk.transaction.model.exception.ContractException;

import java.math.BigInteger;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.List;

@SuppressWarnings("unchecked")
public class UserStorage extends Contract {
    public static final String[] BINARY_ARRAY = {"6080604052600060075560006008553480156200001b57600080fd5b506040805190810160405280600b81526020017f5573657253746f726167650000000000000000000000000000000000000000008152506040805190810160405280600281526020017f69640000000000000000000000000000000000000000000000000000000000008152506040805190810160405280600581526020017f756e5f69640000000000000000000000000000000000000000000000000000008152506040805190810160405280600781526020017f616464726573730000000000000000000000000000000000000000000000000081525060006110019050606060026040519080825280602002602001820160405280156200013c57816020015b6200012862000ce6565b8152602001906001900390816200011e5790505b5090506200015e84620004e36401000000000262003005176401000000009004565b8160008151811015156200016e57fe5b906020019060200201819052506200019a83620004e36401000000000262003005176401000000009004565b816001815181101515620001aa57fe5b906020019060200201819052508173ffffffffffffffffffffffffffffffffffffffff166356004b6a87876200024b856200022e6040805190810160405280600181526020017f2c00000000000000000000000000000000000000000000000000000000000000815250620004e36401000000000262003005176401000000009004565b620005136401000000000262003033179091906401000000009004565b6040518463ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401620002879392919062001019565b602060405180830381600087803b158015620002a257600080fd5b505af1158015620002b7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250620002dd919081019062000fb1565b5060806040519081016040528087815260200186815260200185815260200160006040519080825280602002602001820160405280156200033357816020015b60608152602001906001900390816200031d5790505b508152506000808201518160000190805190602001906200035692919062000d00565b5060208201518160010190805190602001906200037592919062000d00565b5060408201518160020190805190602001906200039492919062000d00565b506060820151816003019080519060200190620003b392919062000d87565b50905050620003d460008585620006a5640100000000026401000000009004565b5050505050506040805190810160405280600281526020017f6964000000000000000000000000000000000000000000000000000000000000815250600490805190602001906200042792919062000dee565b506040805190810160405280600581526020017f756e5f6964000000000000000000000000000000000000000000000000000000815250600590805190602001906200047592919062000dee565b50620004c56040805190810160405280600781526020017f616464726573730000000000000000000000000000000000000000000000000081525062000846640100000000026401000000009004565b60069080519060200190620004dc92919062000e75565b50620010c7565b620004ed62000edc565b600060208301905060408051908101604052808451815260200182815250915050919050565b60606000825114156200053957602060405190810160405280600081525090506200069f565b60006001835103846000015102905060008090505b8351811015620005875783818151811015156200056757fe5b90602001906020020151600001518201915080806001019150506200054e565b506060816040519080825280601f01601f191660200182016040528015620005be5781602001600182028038833980820191505090505b509050600060208201905060008090505b855181101562000697576200062d828783815181101515620005ed57fe5b906020019060200201516020015188848151811015156200060a57fe5b9060200190602002015160000151620009ba640100000000026401000000009004565b85818151811015156200063c57fe5b906020019060200201516000015182019150600186510381101562000689576200067f8288602001518960000151620009ba640100000000026401000000009004565b8660000151820191505b8080600101915050620005cf565b508193505050505b92915050565b82600301829080600181540180825580915050906001820390600052602060002001600090919290919091509080519060200190620006e692919062000dee565b5050620006f262000edc565b6200071182620004e36401000000000262003005176401000000009004565b90506200071d62000edc565b620007716040805190810160405280600181526020017f2c00000000000000000000000000000000000000000000000000000000000000815250620004e36401000000000262003005176401000000009004565b9050600060016200079a838562000a076401000000000262003197179091906401000000009004565b01905060008090505b818110156200083d5786600301620007f1620007d7858762000aa2640100000000026200320e179091906401000000009004565b62000acf6401000000000262003228176401000000009004565b90806001815401808255809150509060018203906000526020600020016000909192909190915090805190602001906200082d92919062000dee565b50508080600101915050620007a3565b50505050505050565b60606200085262000edc565b6200087183620004e36401000000000262003005176401000000009004565b90506200087d62000edc565b620008d16040805190810160405280600181526020017f2c00000000000000000000000000000000000000000000000000000000000000815250620004e36401000000000262003005176401000000009004565b905060606001620008fa838562000a076401000000000262003197179091906401000000009004565b016040519080825280602002602001820160405280156200093057816020015b60608152602001906001900390816200091a5790505b50905060008090505b8151811015620009ae57620009846200096a848662000aa2640100000000026200320e179091906401000000009004565b62000acf6401000000000262003228176401000000009004565b82828151811015156200099357fe5b90602001906020020181905250808060010191505062000939565b50809350505050919050565b5b602081101515620009e25781518352602083019250602082019150602081039050620009bb565b60006001826020036101000a0390508019835116818551168181178652505050505050565b600080826000015162000a3c856000015186602001518660000151876020015162000b43640100000000026401000000009004565b0190505b83600001518460200151018111151562000a9b578180600101925050826000015162000a9285602001518303866000015103838660000151876020015162000b43640100000000026401000000009004565b01905062000a40565b5092915050565b62000aac62000edc565b62000ac883838362000c33640100000000026401000000009004565b5092915050565b60608082600001516040519080825280601f01601f19166020018201604052801562000b0a5781602001600182028038833980820191505090505b509050600060208201905062000b398185602001518660000151620009ba640100000000026401000000009004565b8192505050919050565b6000808490506000868511151562000c235760208511151562000bd757600060018660200360080260020a0319600102905060008186511690506000878a8a0103905060008386511690505b828114151562000bc857818610151562000bb4578a8a01965050505050505062000c2b565b858060010196505083865116905062000b8f565b85965050505050505062000c2b565b60008585209050600091505b8588038211151562000c2157600086842090508082141562000c0c578394505050505062000c2b565b60018401935050818060010192505062000be3565b505b868601925050505b949350505050565b62000c3d62000edc565b600062000c6c856000015186602001518660000151876020015162000b43640100000000026401000000009004565b9050846020015183602001818152505084602001518103836000018181525050846000015185602001510181141562000cb057600085600001818152505062000cdb565b8360000151836000015101856000018181510391508181525050836000015181018560200181815250505b829150509392505050565b604080519081016040528060008152602001600081525090565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f1062000d4357805160ff191683800117855562000d74565b8280016001018555821562000d74579182015b8281111562000d7357825182559160200191906001019062000d56565b5b50905062000d83919062000ef6565b5090565b82805482825590600052602060002090810192821562000ddb579160200282015b8281111562000dda57825182908051906020019062000dc992919062000d00565b509160200191906001019062000da8565b5b50905062000dea919062000f1e565b5090565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f1062000e3157805160ff191683800117855562000e62565b8280016001018555821562000e62579182015b8281111562000e6157825182559160200191906001019062000e44565b5b50905062000e71919062000ef6565b5090565b82805482825590600052602060002090810192821562000ec9579160200282015b8281111562000ec857825182908051906020019062000eb792919062000d00565b509160200191906001019062000e96565b5b50905062000ed8919062000f1e565b5090565b604080519081016040528060008152602001600081525090565b62000f1b91905b8082111562000f1757600081600090555060010162000efd565b5090565b90565b62000f4c91905b8082111562000f48576000818162000f3e919062000f4f565b5060010162000f25565b5090565b90565b50805460018160011615610100020316600290046000825580601f1062000f77575062000f98565b601f01602090049060005260206000209081019062000f97919062000ef6565b5b50565b600062000fa9825162001076565b905092915050565b60006020828403121562000fc457600080fd5b600062000fd48482850162000f9b565b91505092915050565b600062000fea826200106b565b808452620010008160208601602086016200108056","5b6200100b81620010b6565b602085010191505092915050565b6000606082019050818103600083015262001035818662000fdd565b905081810360208301526200104b818562000fdd565b9050818103604083015262001061818462000fdd565b9050949350505050565b600081519050919050565b6000819050919050565b60005b83811015620010a057808201518184015260208101905062001083565b83811115620010b0576000848401525b50505050565b6000601f19601f8301169050919050565b6134ac80620010d76000396000f3fe608060405234801561001057600080fd5b5060043610610074576000357c010000000000000000000000000000000000000000000000000000000090048063864a0d0a14610079578063915ab75514610095578063a14c87ca146100b1578063af7d5eb5146100cd578063dcfefd71146100fd575b600080fd5b610093600480360361008e9190810190612895565b61012e565b005b6100af60048036036100aa91908101906128e9565b6101f3565b005b6100cb60048036036100c69190810190612813565b610390565b005b6100e760048036036100e29190810190612813565b6103f1565b6040516100f49190612b85565b60405180910390f35b61011760048036036101129190810190612813565b610408565b604051610125929190612ba0565b60405180910390f35b60006101398361042a565b50905060008114151515610182576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161017990612dd7565b60405180910390fd5b606060016040519080825280602002602001820160405280156101b957816020015b60608152602001906001900390816101a45790505b5090506101c583610677565b8160008151811015156101d457fe5b906020019060200201819052506101ec848583610a31565b5050505050565b60006101fe8361042a565b509050600081141515610246576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161023d90612df7565b60405180910390fd5b6060600160405190808252806020026020018201604052801561027d57816020015b60608152602001906001900390816102685790505b5090508281600081518110151561029057fe5b90602001906020020181905250610389846006805480602002602001604051908101604052809291908181526020016000905b8282101561037f578382906000526020600020018054600181600116156101000203166002900480601f01602080910402602001604051908101604052809291908181526020018280546001816001161561010002031660029004801561036b5780601f106103405761010080835404028352916020019161036b565b820191906000526020600020905b81548152906001019060200180831161034e57829003601f168201915b5050505050815260200190600101906102c3565b5050505083610e84565b5050505050565b600061039b8261042a565b5090506000811415156103e3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016103da90612db7565b60405180910390fd5b6103ec826113ec565b505050565b6000806103fd83611577565b905080915050919050565b60006060600060606104198561042a565b915091508181935093505050915091565b6000606060006104386117a7565b905060008173ffffffffffffffffffffffffffffffffffffffff1663e8434e39868473ffffffffffffffffffffffffffffffffffffffff16637857d7c96040518163ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040160206040518083038186803b1580156104bb57600080fd5b505afa1580156104cf573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506104f39190810190612746565b6040518363ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040161052c929190612c52565b60206040518083038186803b15801561054457600080fd5b505afa158015610558573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061057c919081019061276f565b905061066c6000600301805480602002602001604051908101604052809291908181526020016000905b82821015610662578382906000526020600020018054600181600116156101000203166002900480601f01602080910402602001604051908101604052809291908181526020018280546001816001161561010002031660029004801561064e5780601f106106235761010080835404028352916020019161064e565b820191906000526020600020905b81548152906001019060200180831161063157829003601f168201915b5050505050815260200190600101906105a6565b505050508261185d565b935093505050915091565b606060008273ffffffffffffffffffffffffffffffffffffffff16600102905060606040805190810160405280601081526020017f303132333435363738396162636465660000000000000000000000000000000081525090506060602a6040519080825280601f01601f1916602001820160405280156107075781602001600182028038833980820191505090505b5090507f300000000000000000000000000000000000000000000000000000000000000081600081518110151561073a57fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053507f780000000000000000000000000000000000000000000000000000000000000081600181518110151561079a57fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535060008090505b6014811015610a255782600485600c84016020811015156107ed57fe5b1a7f0100000000000000000000000000000000000000000000000000000000000000027effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908060020a82049150507f0100000000000000000000000000000000000000000000000000000000000000900460ff1681518110151561086e57fe5b9060200101517f010000000000000000000000000000000000000000000000000000000000000090047f01000000000000000000000000000000000000000000000000000000000000000282600283026002018151811015156108cd57fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535082600f7f01000000000000000000000000000000000000000000000000000000000000000285600c840160208110151561093357fe5b1a7f010000000000000000000000000000000000000000000000000000000000000002167f0100000000000000000000000000000000000000000000000000000000000000900460ff1681518110151561098957fe5b9060200101517f010000000000000000000000000000000000000000000000000000000000000090047f01000000000000000000000000000000000000000000000000000000000000000282600283026003018151811015156109e857fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080806001019150506107d0565b50809350505050919050565b60006001600060030180549050038251141515610a4d57600080fd5b6000806060610a5c8787611e36565b8092508193505050817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1415610e18576000610a966117a7565b905060008173ffffffffffffffffffffffffffffffffffffffff166313db93466040518163ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040160206040518083038186803b158015610afc57600080fd5b505afa158015610b10573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250610b349190810190612798565b90508073ffffffffffffffffffffffffffffffffffffffff1663e942b51660006001018b6040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401610b91929190612d80565b600060405180830381600087803b158015610bab57600080fd5b505af1158015610bbf573d6000803e3d6000fd5b505050508073ffffffffffffffffffffffffffffffffffffffff1663e942b51660006002018a6040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401610c1e929190612d80565b600060405180830381600087803b158015610c3857600080fd5b505af1158015610c4c573d6000803e3d6000fd5b505050506000600190505b600060030180549050811015610d32578173ffffffffffffffffffffffffffffffffffffffff1663e942b516600060030183815481101515610c9557fe5b906000526020600020018a60018503815181101515610cb057fe5b906020019060200201516040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401610cf3929190612d49565b600060405180830381600087803b158015610d0d57600080fd5b505af1158015610d21573d6000803e3d6000fd5b505050508080600101915050610c57565b508173ffffffffffffffffffffffffffffffffffffffff166331afac368a836040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401610d8a929190612c82565b602060405180830381600087803b158015610da457600080fd5b505af1158015610db8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250610ddc91908101906127ea565b60011415610ded5760009450610e11565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe94505b5050610e3c565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff92505b7f9994ba29bf7f93f869f42bc2c06a947ca883df73b7c6eb95482a190d7e437cd2838888604051610e6f93929190612bd0565b60405180910390a18293505050509392505050565b600081518351141515610ecc576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ec390612e17565b60405180910390fd5b6000610ed66117a7565b905060008173ffffffffffffffffffffffffffffffffffffffff1663e8434e39878473ffffffffffffffffffffffffffffffffffffffff16637857d7c96040518163ffffffff167c01000000000000000000","0000000000000000000000000000000000000002815260040160206040518083038186803b158015610f5957600080fd5b505afa158015610f6d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250610f919190810190612746565b6040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401610fca929190612c52565b60206040518083038186803b158015610fe257600080fd5b505afa158015610ff6573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061101a919081019061276f565b905060008173ffffffffffffffffffffffffffffffffffffffff1663949d225d6040518163ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040160206040518083038186803b15801561108057600080fd5b505afa158015611094573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506110b891908101906127ea565b14156110e8577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff925050506113e5565b60008173ffffffffffffffffffffffffffffffffffffffff1663846719e060006040518263ffffffff167c01000000000000000000000000000000000000000000000000000000000281526004016111409190612c15565b60206040518083038186803b15801561115857600080fd5b505afa15801561116c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506111909190810190612798565b905060008090505b8651811015611265578173ffffffffffffffffffffffffffffffffffffffff1663e942b51688838151811015156111cb57fe5b9060200190602002015188848151811015156111e357fe5b906020019060200201516040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401611226929190612cf0565b600060405180830381600087803b15801561124057600080fd5b505af1158015611254573d6000803e3d6000fd5b505050508080600101915050611198565b5060018373ffffffffffffffffffffffffffffffffffffffff1663bf2b70a189848773ffffffffffffffffffffffffffffffffffffffff16637857d7c96040518163ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040160206040518083038186803b1580156112e857600080fd5b505afa1580156112fc573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506113209190810190612746565b6040518463ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040161135a93929190612cb2565b602060405180830381600087803b15801561137457600080fd5b505af1158015611388573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506113ac91908101906127ea565b14156113be57600093505050506113e5565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe93505050505b9392505050565b6000806113f76117a7565b905060018173ffffffffffffffffffffffffffffffffffffffff166328bb2117858473ffffffffffffffffffffffffffffffffffffffff16637857d7c96040518163ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040160206040518083038186803b15801561147a57600080fd5b505afa15801561148e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506114b29190810190612746565b6040518363ffffffff167c01000000000000000000000000000000000000000000000000000000000281526004016114eb929190612c52565b602060405180830381600087803b15801561150557600080fd5b505af1158015611519573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061153d91908101906127ea565b141561154d576000915050611572565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9150505b919050565b6000806115826117a7565b905060008173ffffffffffffffffffffffffffffffffffffffff16637857d7c96040518163ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040160206040518083038186803b1580156115e857600080fd5b505afa1580156115fc573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506116209190810190612746565b905060008273ffffffffffffffffffffffffffffffffffffffff1663e8434e3986846040518363ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040161167b929190612c52565b60206040518083038186803b15801561169357600080fd5b505afa1580156116a7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506116cb919081019061276f565b905060008173ffffffffffffffffffffffffffffffffffffffff1663949d225d6040518163ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040160206040518083038186803b15801561173157600080fd5b505afa158015611745573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061176991908101906127ea565b141561179a577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff93505050506117a2565b600093505050505b919050565b60008061100190508073ffffffffffffffffffffffffffffffffffffffff1663f23f63c9600080016040518263ffffffff167c01000000000000000000000000000000000000000000000000000000000281526004016118079190612d27565b60206040518083038186803b15801561181f57600080fd5b505afa158015611833573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061185791908101906127c1565b91505090565b60006060808373ffffffffffffffffffffffffffffffffffffffff1663949d225d6040518163ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040160206040518083038186803b1580156118c457600080fd5b505afa1580156118d8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506118fc91908101906127ea565b60001415611933577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff818191509250925050611e2f565b6040805190810160405280600181526020017f5b00000000000000000000000000000000000000000000000000000000000000815250905060008090505b8473ffffffffffffffffffffffffffffffffffffffff1663949d225d6040518163ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040160206040518083038186803b1580156119d357600080fd5b505afa1580156119e7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250611a0b91908101906127ea565b811015611de1576060611ac2878773ffffffffffffffffffffffffffffffffffffffff1663846719e0856040518263ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401611a6d9190612b85565b60206040518083038186803b158015611a8557600080fd5b505afa158015611a99573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250611abd9190810190612798565b612116565b905060008090505b8151811015611ceb576000811415611b6d57611b6a846040805190810160405280600a81526020017f7b22696e646578223a2200000000000000000000000000000000000000000000815250846000815181101515611b2557fe5b906020019060200201516040805190810160405280600381526020017f222c7b0000000000000000000000000000000000000000000000000000000000815250612254565b93505b611c48846040805190810160405280600181526020017f22000000000000000000000000000000000000000000000000000000000000008152508a84815181101515611bb557fe5b906020019060200201516040805190810160405280600381526020017f223a2200000000000000000000000000000000000000000000000000000000008152508686815181101515611c0357fe5b906020019060200201516040805190810160405280600181526020017f2200000000000000000000000000000000000000000000000000000000000000815250612317565b93506001825103811415611c9c57611c95846040805190810160405280600281526020017f7d7d000000000000000000000000000000000000000000000000000000000000815250612416565b9350611cde565b611cdb846040805190810160405280600181526020017f2c00000000000000000000000000000000000000000000000000000000000000815250612416565b93505b8080600101915050611aca565b5060018673ffffffffffffffffffffffffffffffffffffffff1663949d225d6040518163ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040160206040518083038186803b158015611d5057600080fd5b505afa158015611d64573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250611d8891908101906127ea565b0382141515611dd357611dd0836040805190810160405280600181526020017f2c00000000000000000000000000000000000000000000000000000000000000815250612416565b92505b508080600101915050611971565b50611e21816040805190810160405280600181526020017f5d00000000000000000000000000000000000000000000000000000000000000815250612416565b905060008181915092509250505b9250929050565b600060606000611e446117a7565b905060008173ffffffffffffffffffffffffffffffffffffffff16637857d7c96040518163ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040160206040518083038186803b158015611eaa57600080fd5b505afa158015611ebe573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250611ee29190810190612746565b90508073ffffffffffffffffffffffffffffffffffffffff1663cd30a1d16000600201876040518363ffffffff167c0100000000000000000000000000000000000000000000","000000000000028152600401611f3f929190612d80565b60006040518083038186803b158015611f5757600080fd5b505afa158015611f6b573d6000803e3d6000fd5b5050505060008273ffffffffffffffffffffffffffffffffffffffff1663e8434e3988846040518363ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401611fc8929190612c52565b60206040518083038186803b158015611fe057600080fd5b505afa158015611ff4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250612018919081019061276f565b90506121086000600301805480602002602001604051908101604052809291908181526020016000905b828210156120fe578382906000526020600020018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156120ea5780601f106120bf576101008083540402835291602001916120ea565b820191906000526020600020905b8154815290600101906020018083116120cd57829003601f168201915b505050505081526020019060010190612042565b505050508261185d565b945094505050509250929050565b606080835160405190808252806020026020018201604052801561214e57816020015b60608152602001906001900390816121395790505b50905060008090505b8451811015612249578373ffffffffffffffffffffffffffffffffffffffff16639c981fcb868381518110151561218a57fe5b906020019060200201516040518263ffffffff167c01000000000000000000000000000000000000000000000000000000000281526004016121cc9190612c30565b60006040518083038186803b1580156121e457600080fd5b505afa1580156121f8573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f820116820180604052506122219190810190612854565b828281518110151561222f57fe5b906020019060200201819052508080600101915050612157565b508091505092915050565b606080600460405190808252806020026020018201604052801561228c57816020015b60608152602001906001900390816122775790505b5090508581600081518110151561229f57fe5b90602001906020020181905250848160018151811015156122bc57fe5b90602001906020020181905250838160028151811015156122d957fe5b90602001906020020181905250828160038151811015156122f657fe5b9060200190602002018190525061230c8161249d565b915050949350505050565b606080600660405190808252806020026020018201604052801561234f57816020015b606081526020019060019003908161233a5790505b5090508781600081518110151561236257fe5b906020019060200201819052508681600181518110151561237f57fe5b906020019060200201819052508581600281518110151561239c57fe5b90602001906020020181905250848160038151811015156123b957fe5b90602001906020020181905250838160048151811015156123d657fe5b90602001906020020181905250828160058151811015156123f357fe5b906020019060200201819052506124098161249d565b9150509695505050505050565b606080600260405190808252806020026020018201604052801561244e57816020015b60608152602001906001900390816124395790505b5090508381600081518110151561246157fe5b906020019060200201819052508281600181518110151561247e57fe5b906020019060200201819052506124948161249d565b91505092915050565b6060600080905060008090505b83518110156124dd5783818151811015156124c157fe5b90602001906020020151518201915080806001019150506124aa565b506060816040519080825280601f01601f1916602001820160405280156125135781602001600182028038833980820191505090505b5090506060819050600080905060008090505b8651811015612615576060878281518110151561253f57fe5b90602001906020020151905060008090505b815181101561260657818181518110151561256857fe5b9060200101517f010000000000000000000000000000000000000000000000000000000000000090047f01000000000000000000000000000000000000000000000000000000000000000285858151811015156125c157fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535083806001019450508080600101915050612551565b50508080600101915050612526565b5081945050505050919050565b600061262e8235612ef4565b905092915050565b60006126428251612f06565b905092915050565b60006126568251612f18565b905092915050565b600061266a8251612f2a565b905092915050565b600061267e8251612f3c565b905092915050565b60006126928251612f4e565b905092915050565b600082601f83011215156126ad57600080fd5b81356126c06126bb82612e64565b612e37565b915080825260208301602083018583830111156126dc57600080fd5b6126e7838284612fb2565b50505092915050565b600082601f830112151561270357600080fd5b815161271661271182612e64565b612e37565b9150808252602083016020830185838301111561273257600080fd5b61273d838284612fc1565b50505092915050565b60006020828403121561275857600080fd5b600061276684828501612636565b91505092915050565b60006020828403121561278157600080fd5b600061278f8482850161264a565b91505092915050565b6000602082840312156127aa57600080fd5b60006127b88482850161265e565b91505092915050565b6000602082840312156127d357600080fd5b60006127e184828501612672565b91505092915050565b6000602082840312156127fc57600080fd5b600061280a84828501612686565b91505092915050565b60006020828403121561282557600080fd5b600082013567ffffffffffffffff81111561283f57600080fd5b61284b8482850161269a565b91505092915050565b60006020828403121561286657600080fd5b600082015167ffffffffffffffff81111561288057600080fd5b61288c848285016126f0565b91505092915050565b600080604083850312156128a857600080fd5b600083013567ffffffffffffffff8111156128c257600080fd5b6128ce8582860161269a565b92505060206128df85828601612622565b9150509250929050565b600080604083850312156128fc57600080fd5b600083013567ffffffffffffffff81111561291657600080fd5b6129228582860161269a565b925050602083013567ffffffffffffffff81111561293f57600080fd5b61294b8582860161269a565b9150509250929050565b61295e81612f58565b82525050565b61296d81612f7c565b82525050565b61297c81612eca565b82525050565b61298b81612fa0565b82525050565b600061299c82612ead565b8084526129b0816020860160208601612fc1565b6129b981612ff4565b602085010191505092915050565b60006129d282612ea2565b8084526129e6816020860160208601612fc1565b6129ef81612ff4565b602085010191505092915050565b600081546001811660008114612a1a5760018114612a3a57612a7b565b607f600283041680865260ff198316602087015260408601935050612a7b565b60028204808652602086019550612a5085612e90565b60005b82811015612a7257815481890152600182019150602081019050612a53565b80880195505050505b505092915050565b6000600d82527f6b6579206e6f7420666f756e64000000000000000000000000000000000000006020830152604082019050919050565b6000600a82527f6b657920657869747321000000000000000000000000000000000000000000006020830152604082019050919050565b6000600e82527f6b6579206e6f74206578697473210000000000000000000000000000000000006020830152604082019050919050565b6000602482527f4669656c647320616e64206e657756616c756573206c656e677468206d69736d60208301527f61746368000000000000000000000000000000000000000000000000000000006040830152606082019050919050565b6000602082019050612b9a6000830184612973565b92915050565b6000604082019050612bb56000830185612973565b8181036020830152612bc78184612991565b90509392505050565b6000606082019050612be56000830186612973565b8181036020830152612bf78185612991565b90508181036040830152612c0b8184612991565b9050949350505050565b6000602082019050612c2a6000830184612982565b92915050565b60006020820190508181036000830152612c4a81846129c7565b905092915050565b60006040820190508181036000830152612c6c8185612991565b9050612c7b6020830184612955565b9392505050565b60006040820190508181036000830152612c9c8185612991565b9050612cab6020830184612964565b9392505050565b60006060820190508181036000830152612ccc8186612991565b9050612cdb6020830185612964565b612ce86040830184612955565b949350505050565b60006040820190508181036000830152612d0a81856129c7565b90508181036020830152612d1e81846129c7565b90509392505050565b60006020820190508181036000830152612d4181846129fd565b905092915050565b60006040820190508181036000830152612d6381856129fd565b90508181036020830152612d7781846129c7565b90509392505050565b60006040820190508181036000830152612d9a81856129fd565b90508181036020830152612dae8184612991565b90509392505050565b60006020820190508181036000830152612dd081612a83565b9050919050565b60006020820190508181036000830152612df081612aba565b9050919050565b60006020820190508181036000830152612e1081612af1565b9050919050565b60006020820190508181036000830152612e3081612b28565b9050919050565b6000604051905081810181811067ffffffffffffffff82111715612e5a57600080fd5b8060405250919050565b600067ffffffffffffffff821115612e7b57600080fd5b601f19601f8301169050602081019050919050565b60008160005260206000209050919050565b600081519050919050565b600081519050919050565b6000612ec382612ed4565b9050919050565b6000819050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000612eff82612ed4565b9050919050565b6000612f1182612eb8565b9050919050565b6000612f2382612eb8565b9050919050","565b6000612f3582612eb8565b9050919050565b6000612f4782612eb8565b9050919050565b6000819050919050565b6000612f6382612f6a565b9050919050565b6000612f7582612ed4565b9050919050565b6000612f8782612f8e565b9050919050565b6000612f9982612ed4565b9050919050565b6000612fab82612eca565b9050919050565b82818337600083830152505050565b60005b83811015612fdf578082015181840152602081019050612fc4565b83811115612fee576000848401525b50505050565b6000601f19601f8301169050919050565b61300d613458565b600060208301905060408051908101604052808451815260200182815250915050919050565b60606000825114156130575760206040519081016040528060008152509050613191565b60006001835103846000015102905060008090505b83518110156130a257838181518110151561308357fe5b906020019060200201516000015182019150808060010191505061306c565b506060816040519080825280601f01601f1916602001820160405280156130d85781602001600182028038833980820191505090505b509050600060208201905060008090505b85518110156131895761313382878381518110151561310457fe5b9060200190602002015160200151888481518110151561312057fe5b906020019060200201516000015161328a565b858181518110151561314157fe5b906020019060200201516000015182019150600186510381101561317c57613172828860200151896000015161328a565b8660000151820191505b80806001019150506130e9565b508193505050505b92915050565b60008082600001516131bb85600001518660200151866000015187602001516132d5565b0190505b83600001518460200151018111151561320757818060010192505082600001516131ff8560200151830386600001510383866000015187602001516132d5565b0190506131bf565b5092915050565b613216613458565b6132218383836133ba565b5092915050565b60608082600001516040519080825280601f01601f1916602001820160405280156132625781602001600182028038833980820191505090505b5090506000602082019050613280818560200151866000015161328a565b8192505050919050565b5b6020811015156132b0578151835260208301925060208201915060208103905061328b565b60006001826020036101000a0390508019835116818551168181178652505050505050565b600080849050600086851115156133aa5760208511151561336257600060018660200360080260020a0319600102905060008186511690506000878a8a0103905060008386511690505b8281141515613354578186101515613341578a8a0196505050505050506133b2565b858060010196505083865116905061331f565b8596505050505050506133b2565b60008585209050600091505b858803821115156133a857600086842090508082141561339457839450505050506133b2565b60018401935050818060010192505061336e565b505b868601925050505b949350505050565b6133c2613458565b60006133e085600001518660200151866000015187602001516132d5565b9050846020015183602001818152505084602001518103836000018181525050846000015185602001510181141561342257600085600001818152505061344d565b8360000151836000015101856000018181510391508181525050836000015181018560200181815250505b829150509392505050565b60408051908101604052806000815260200160008152509056fea265627a7a72305820c686d8f5e7984861997a66420b84f6f0460c7ccee30e4dcde3ceebf6e535bf6d6c6578706572696d656e74616cf50037"};

    public static final String BINARY = org.fisco.bcos.sdk.utils.StringUtils.joinAll("", BINARY_ARRAY);

    public static final String[] SM_BINARY_ARRAY = {};

    public static final String SM_BINARY = org.fisco.bcos.sdk.utils.StringUtils.joinAll("", SM_BINARY_ARRAY);

    public static final String[] ABI_ARRAY = {"[{\"constant\":false,\"inputs\":[{\"name\":\"un_id\",\"type\":\"string\"},{\"name\":\"_address\",\"type\":\"address\"}],\"name\":\"addUser\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"un_id\",\"type\":\"string\"},{\"name\":\"_address\",\"type\":\"string\"}],\"name\":\"updateMap\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"key\",\"type\":\"string\"}],\"name\":\"deleteMap\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"un_id\",\"type\":\"string\"}],\"name\":\"existMap\",\"outputs\":[{\"name\":\"\",\"type\":\"int256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"un_id\",\"type\":\"string\"}],\"name\":\"readMap\",\"outputs\":[{\"name\":\"\",\"type\":\"int256\"},{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"name\":\"retCode\",\"type\":\"int256\"},{\"indexed\":false,\"name\":\"primaryKey\",\"type\":\"string\"},{\"indexed\":false,\"name\":\"uniqueKey\",\"type\":\"string\"}],\"name\":\"AddEvent\",\"type\":\"event\"}]"};

    public static final String ABI = org.fisco.bcos.sdk.utils.StringUtils.joinAll("", ABI_ARRAY);

    public static final String FUNC_ADDUSER = "addUser";

    public static final String FUNC_UPDATEMAP = "updateMap";

    public static final String FUNC_DELETEMAP = "deleteMap";

    public static final String FUNC_EXISTMAP = "existMap";

    public static final String FUNC_READMAP = "readMap";

    public static final Event ADDEVENT_EVENT = new Event("AddEvent",
            Arrays.<TypeReference<?>>asList(new TypeReference<Int256>() {}, new TypeReference<Utf8String>() {}, new TypeReference<Utf8String>() {}));
    ;

    protected UserStorage(String contractAddress, Client client, CryptoKeyPair credential) {
        super(getBinary(client.getCryptoSuite()), contractAddress, client, credential);
    }

    public static String getBinary(CryptoSuite cryptoSuite) {
        return (cryptoSuite.getCryptoTypeConfig() == CryptoType.ECDSA_TYPE ? BINARY : SM_BINARY);
    }

    public TransactionReceipt addUser(String un_id, String _address) {
        final Function function = new Function(
                FUNC_ADDUSER,
                Arrays.<Type>asList(new Utf8String(un_id),
                new Address(_address)),
                Collections.<TypeReference<?>>emptyList());
        return executeTransaction(function);
    }

    public void addUser(String un_id, String _address, TransactionCallback callback) {
        final Function function = new Function(
                FUNC_ADDUSER,
                Arrays.<Type>asList(new Utf8String(un_id),
                new Address(_address)),
                Collections.<TypeReference<?>>emptyList());
          asyncExecuteTransaction(function, callback);
    }

    public String getSignedTransactionForAddUser(String un_id, String _address) {
        final Function function = new Function(
                FUNC_ADDUSER,
                Arrays.<Type>asList(new Utf8String(un_id),
                new Address(_address)),
                Collections.<TypeReference<?>>emptyList());
        return createSignedTransaction(function);
    }

    public Tuple2<String, String> getAddUserInput(TransactionReceipt transactionReceipt) {
        String data = transactionReceipt.getInput().substring(10);
        final Function function = new Function(FUNC_ADDUSER,
                Arrays.<Type>asList(),
                Arrays.<TypeReference<?>>asList(new TypeReference<Utf8String>() {}, new TypeReference<Address>() {}));
        List<Type> results = FunctionReturnDecoder.decode(data, function.getOutputParameters());
        return new Tuple2<String, String>(

                (String) results.get(0).getValue(),
                (String) results.get(1).getValue()
                );
    }

    public TransactionReceipt updateMap(String un_id, String _address) {
        final Function function = new Function(
                FUNC_UPDATEMAP,
                Arrays.<Type>asList(new Utf8String(un_id),
                new Utf8String(_address)),
                Collections.<TypeReference<?>>emptyList());
        return executeTransaction(function);
    }

    public void updateMap(String un_id, String _address, TransactionCallback callback) {
        final Function function = new Function(
                FUNC_UPDATEMAP,
                Arrays.<Type>asList(new Utf8String(un_id),
                new Utf8String(_address)),
                Collections.<TypeReference<?>>emptyList());
          asyncExecuteTransaction(function, callback);
    }

    public String getSignedTransactionForUpdateMap(String un_id, String _address) {
        final Function function = new Function(
                FUNC_UPDATEMAP,
                Arrays.<Type>asList(new Utf8String(un_id),
                new Utf8String(_address)),
                Collections.<TypeReference<?>>emptyList());
        return createSignedTransaction(function);
    }

    public Tuple2<String, String> getUpdateMapInput(TransactionReceipt transactionReceipt) {
        String data = transactionReceipt.getInput().substring(10);
        final Function function = new Function(FUNC_UPDATEMAP,
                Arrays.<Type>asList(),
                Arrays.<TypeReference<?>>asList(new TypeReference<Utf8String>() {}, new TypeReference<Utf8String>() {}));
        List<Type> results = FunctionReturnDecoder.decode(data, function.getOutputParameters());
        return new Tuple2<String, String>(

                (String) results.get(0).getValue(),
                (String) results.get(1).getValue()
                );
    }

    public TransactionReceipt deleteMap(String key) {
        final Function function = new Function(
                FUNC_DELETEMAP,
                Arrays.<Type>asList(new Utf8String(key)),
                Collections.<TypeReference<?>>emptyList());
        return executeTransaction(function);
    }

    public void deleteMap(String key, TransactionCallback callback) {
        final Function function = new Function(
                FUNC_DELETEMAP,
                Arrays.<Type>asList(new Utf8String(key)),
                Collections.<TypeReference<?>>emptyList());
          asyncExecuteTransaction(function, callback);
    }

    public String getSignedTransactionForDeleteMap(String key) {
        final Function function = new Function(
                FUNC_DELETEMAP,
                Arrays.<Type>asList(new Utf8String(key)),
                Collections.<TypeReference<?>>emptyList());
        return createSignedTransaction(function);
    }

    public Tuple1<String> getDeleteMapInput(TransactionReceipt transactionReceipt) {
        String data = transactionReceipt.getInput().substring(10);
        final Function function = new Function(FUNC_DELETEMAP,
                Arrays.<Type>asList(),
                Arrays.<TypeReference<?>>asList(new TypeReference<Utf8String>() {}));
        List<Type> results = FunctionReturnDecoder.decode(data, function.getOutputParameters());
        return new Tuple1<String>(

                (String) results.get(0).getValue()
                );
    }

    public BigInteger existMap(String un_id) throws ContractException {
        final Function function = new Function(FUNC_EXISTMAP,
                Arrays.<Type>asList(new Utf8String(un_id)),
                Arrays.<TypeReference<?>>asList(new TypeReference<Int256>() {}));
        return executeCallWithSingleValueReturn(function, BigInteger.class);
    }

    public Tuple2<BigInteger, String> readMap(String un_id) throws ContractException {
        final Function function = new Function(FUNC_READMAP,
                Arrays.<Type>asList(new Utf8String(un_id)),
                Arrays.<TypeReference<?>>asList(new TypeReference<Int256>() {}, new TypeReference<Utf8String>() {}));
        List<Type> results = executeCallWithMultipleValueReturn(function);
        return new Tuple2<BigInteger, String>(
                (BigInteger) results.get(0).getValue(),
                (String) results.get(1).getValue());
    }

    public List<AddEventEventResponse> getAddEventEvents(TransactionReceipt transactionReceipt) {
        List<EventValuesWithLog> valueList = extractEventParametersWithLog(ADDEVENT_EVENT, transactionReceipt);
        ArrayList<AddEventEventResponse> responses = new ArrayList<AddEventEventResponse>(valueList.size());
        for (EventValuesWithLog eventValues : valueList) {
            AddEventEventResponse typedResponse = new AddEventEventResponse();
            typedResponse.log = eventValues.getLog();
            typedResponse.retCode = (BigInteger) eventValues.getNonIndexedValues().get(0).getValue();
            typedResponse.primaryKey = (String) eventValues.getNonIndexedValues().get(1).getValue();
            typedResponse.uniqueKey = (String) eventValues.getNonIndexedValues().get(2).getValue();
            responses.add(typedResponse);
        }
        return responses;
    }

    public void subscribeAddEventEvent(String fromBlock, String toBlock, List<String> otherTopics, EventCallback callback) {
        String topic0 = eventEncoder.encode(ADDEVENT_EVENT);
        subscribeEvent(ABI,BINARY,topic0,fromBlock,toBlock,otherTopics,callback);
    }

    public void subscribeAddEventEvent(EventCallback callback) {
        String topic0 = eventEncoder.encode(ADDEVENT_EVENT);
        subscribeEvent(ABI,BINARY,topic0,callback);
    }

    public static UserStorage load(String contractAddress, Client client, CryptoKeyPair credential) {
        return new UserStorage(contractAddress, client, credential);
    }

    public static UserStorage deploy(Client client, CryptoKeyPair credential) throws ContractException {
        return deploy(UserStorage.class, client, credential, getBinary(client.getCryptoSuite()), "");
    }

    public static class AddEventEventResponse {
        public TransactionReceipt.Logs log;

        public BigInteger retCode;

        public String primaryKey;

        public String uniqueKey;
    }
}
